//
//  NoticeContentViewController.m
//  OA
//
//  Created by apple on 15-11-5.
//  Copyright (c) 2015年 net. All rights reserved.
//

#import "NoticeContentViewController.h"
#import "AppDelegate.h"
#import "Constants.h"
@interface NoticeContentViewController ()

@end

@implementation NoticeContentViewController
NSArray * notice;
AppDelegate * appDelegate;
- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    //NSLog(@"%@",self.noticeId);
    self.navigationItem.title=@"通告内容";
    appDelegate = [UIApplication sharedApplication].delegate;
    NSDictionary * params = @{@"id":self.noticeId};
    [appDelegate.manager
     POST:url3
     parameters:params
     success:^(AFHTTPRequestOperation *operation, id responseObject) {
         [self.indicator stopAnimating];
         notice = responseObject;
         NSDictionary * dict = [notice objectAtIndex:0];
         self.noticeTitle.text = [dict objectForKey:@"title"];
         [self.webView loadHTMLString:[dict objectForKey:@"desc"] baseURL:nil];
     } failure:^(AFHTTPRequestOperation *operation, NSError *error) {
         NSLog(@"他妈的异常:%@",error);
     }];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
 #pragma mark - Navigation
 
 // In a storyboard-based application, you will often want to do a little preparation before navigation
 - (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
 // Get the new view controller using [segue destinationViewController].
 // Pass the selected object to the new view controller.
 }
 */

@end
